<{include file="page/header.htm"}>
<div class="page-content">
                <!-- Page Breadcrumb -->
                <div class="page-breadcrumbs">
                    <ul class="breadcrumb">
                        <li>
                            <i class="fa fa-home"></i>
                            <a href="#">系统管理</a>
                        </li>
                        <li class="active">合作品牌管理</li>
                    </ul>
                </div>
                <!-- /Page Breadcrumb -->
                
                <!-- Page Header -->
                <div class="page-header position-relative">
                    <div class="header-title">
                        <h1>
                            合作品牌管理
                        </h1>
                        <small>
                                <i class="fa fa-angle-right"></i>
                                <{if $item}>编辑<{else}>添加<{/if}>合作品牌
                       </small>
                    </div>
                    <!--Header Buttons-->
                    <div class="header-buttons">
                        <a class="sidebar-toggler" href="#">
                            <i class="fa fa-arrows-h"></i>
                        </a>
                        <a class="refresh" id="refresh-toggler" href="">
                            <i class="glyphicon glyphicon-refresh"></i>
                        </a>
                        <a class="fullscreen" id="fullscreen-toggler" href="#">
                            <i class="glyphicon glyphicon-fullscreen"></i>
                        </a>
                    </div>
                    <!--Header Buttons End-->
                </div>
                <!-- /Page Header -->
                <!-- Page Body -->
                <div class="page-body">
                
                  <{include file="page/msg.htm"}>
                
                <div class="row">
                                <div class="col-lg-12 col-sm-12 col-xs-12">
                                    <div class="widget radius-bordered">
                                        <div class="widget-header bg-themeprimary">
                                            <span class="widget-caption"><{if $item}>编辑<{else}>添加<{/if}>合作品牌</span>
                                            <div class="widget-buttons">
                                               <button type="button" class="btn btn-success" onclick="window.location='<{url path='link/index'}>';"><i class="fa fa-mail-reply-all"></i>返回</button> 
                                            </div>
                                        </div>
                                        <div class="widget-body">
                                            <div class="row">
                                            	<div class="col-sm-6 col-xs-6">
                                                <form id="dataForm" enctype="multipart/form-data" method="post" class="form-horizontal" action="<{url path='link/edit'}>">
                                                 <input type="hidden" name="id" value="">
                                                 
                                                    <div class="form-group">
                                                        <label class="col-lg-4 control-label">合作品牌<span class="red">*</span></label>
                                                        <div class="col-lg-8">
                                                            <input type="text" class="form-control" name="link_name" datatype="s2-100"  nullmsg="品牌名不能为空!" errormsg="品牌名至少2个字符,最多10个字符！" />
                                                        </div>
                                                    </div>                                                    
                                                    
                                                    <div class="form-group">
                                                        <label class="col-lg-4 control-label">图片</label>
                                                        <div class="col-lg-8">
                                                            <input type="file" name="link_img"  accept=".jpeg,.jpg,.png,.git,.bmp"/>
                                                            <{if $item->link_img }>
                                                            	<a target="_blank" href="<{$item->link_img}>"><img src="<{$item->link_img}>" width="100" height="50" /></a>
                                                            <{/if}>
                                                        </div>
                                                    </div>
                                                    
                                                    
                                                    <div class="form-group">
                                                        <label class="col-lg-4 control-label">链接地址</label>
                                                        <div class="col-lg-8">
                                                            <input type="text" class="form-control" name="link_url" />
                                                        </div>
                                                    </div>
                                                    
                                            
                                                    <div class="form-group">
                                                        <div class="col-lg-offset-4 col-lg-8">
                                                            <input class="btn btn-primary" type="submit" value="提交" />
                                                            <button type="button" class="btn btn-warning" onclick="window.location='<{url path='link/index'}>';">返回</button> 
                                                        </div>
                                                    </div>
                                            </form>
                                                </div>
                                            </div>
                                        </div>
                                    </div>
                                </div>
                                
                            </div>  
                
                </div>
                <!-- /Page Body -->
            </div>
<{include file="page/footer.htm"}>
<script src="/skin/adminhtml/js/form.js"></script>
<script src="/skin/adminhtml/js/Validform.js"></script>
<script src="/skin/adminhtml/js/tools.js"></script>
<script type="text/javascript">
	$(document).ready(function () {
		validate('#dataForm');
	    var form = new Form('dataForm');
		form.init(<{json data=$item}>);
	});
</script>